<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta content="width=device-width, initial-scale=1.0" name="viewport">
  <title>Video Pause Test</title>
</head>

<body>
  <video controls height="360" id="myVideo1" width="640">
    <source
      src="https://vd2.bdstatic.com/mda-pm68mkxgax2mwydj/sc/cae_h264/1701958902456543503/mda-pm68mkxgax2mwydj.mp4?v_from_s=hkapp-haokan-hbf&auth_key=1703753049-0-0-952d747c497ad77ea1b953d042357beb&bcevod_channel=searchbox_feed&pd=1&cr=2&cd=0&pt=3&logid=2649216236&vid=7962020702593201339&klogid=2649216236&abtest="
      type="video/mp4">
    Your browser does not support the video tag.
  </video>
  <button onclick="playVideo()">playVideo</button>

  <script>
    function pauseVideo() {
      var videoElement = document.getElementById('myVideo1');
      videoElement.pause();
    }
    function playVideo() {
      var videoElement = document.getElementById('myVideo1');
      videoElement.play();
    }
    function enterFullScreen() {
      var videoElement = document.getElementById('myVideo1');
      if (!videoElement.fullscreenElement) {
        if (videoElement.requestFullscreen) {
          videoElement.requestFullscreen();
        } else if (videoElement.mozRequestFullScreen) {
          videoElement.mozRequestFullScreen();
        } else if (videoElement.webkitRequestFullscreen) {
          videoElement.webkitRequestFullscreen();
        } else if (videoElement.msRequestFullscreen) {
          videoElement.msRequestFullscreen();
        }
      }
    }
    function exitFullScreen() {
      var videoElement = document.getElementById('myVideo1');
      if (videoElement.exitFullscreen) {
        videoElement.exitFullscreen();
      } else if (videoElement.mozCancelFullScreen) {
        videoElement.mozCancelFullScreen();
      } else if (videoElement.webkitExitFullscreen) {
        videoElement.webkitExitFullscreen();
      } else if (videoElement.msExitFullscreen) {
        videoElement.msExitFullscreen();
      }
    }
    function isVideoFullScreen() {
      var videoElement = document.getElementById('myVideo1');
      if (!videoElement) {
        return 0;
      }
      if (document.fullscreenElement === videoElement ||
        document.mozFullScreenElement === videoElement ||
        document.webkitFullscreenElement === videoElement ||
        document.msFullscreenElement === videoElement) {
        return 1;
      } else {
        return 0;
      }
    }
  </script>

</body>

</html>